<?php echo $this->Html->css('deal'); ?>
<div class="drow" id="deal_<?=$deal['Deal']['id']?>">
	<div class="dleft">
		<?=$html->image('posts/'.$deal['Product']['image'], array('class' => 'deal-picture'));?>
	</div>
	<div class="dmid">
		<?= $html->link($deal['Product']['name'], '/products/view/'.$deal['Product']['id']); ?>
		<p>Price: $<?=$deal['Deal']['price']?></p>
		<p>Seller: <a href="<?=$this->webroot?>users/view/<?=$deal['User']['id']?>"><?=$deal['User']['name']?></a></p>
		<p>On: <?=$deal['Deal']['created']?></p>
	</div>
	<div class="dright">
		<?if (!strcmp($page,'cart') || (isset($deal['InCart']) && $deal['InCart'])){?>
			<div class="remove_from_cart btn" id="<?=$deal['Deal']['id']?>_remove" style="width:100%">Remove from cart</div>
			<div class="add_to_cart btn" id="<?=$deal['Deal']['id']?>_add" style="display:none;width:100%">Add to cart</div>
		<?}else{?>
			<div class="add_to_cart btn" id="<?=$deal['Deal']['id']?>_add" style="width:100%">Add to cart</div>
			<div class="remove_from_cart btn" id="<?=$deal['Deal']['id']?>_remove" style="display:none;width:100%">Remove from cart</div>
		<?}?>
	</div>
</div>